package cn.join.ideer.common.req;

import cn.join.ideer.common.enums.CommentType;
import cn.join.ideer.common.vo.TokenRequestVo;
import lombok.Data;
import lombok.ToString;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @author shinyiqi
 * @date 2023/3/5 16:03
 */

@Data
@ToString
public class IdeerCommentReqDto extends TokenRequestVo {

    @NotNull(message = "评论类型不能为空")
    private CommentType objType;
    @NotNull(message = "被评论对象不能为空")
    @Min(value = 1, message = "objId必须为正整数")
    private Long objId;
    private Long parentId;
    @NotBlank(message = "评论不能为空")
    private String content;

}
